package com.sh.data.engine.opentsdb.client.util;

import java.text.ParseException;
import java.text.SimpleDateFormat;
import java.util.Date;

/**
 * @author tinglan.ys
 * @description:
 * @date 2022/10/12 上午9:34
 */
public class DateTimeUtil {
    public static Date parse(String date, String fm) {
        Date res = null;
        try {
            SimpleDateFormat sft = new SimpleDateFormat(fm);
            res = sft.parse(date);
        } catch (ParseException e) {
            e.printStackTrace();
        }
        return res;
    }
}
